package com.caval.dao;

import com.caval.bean.User;

import java.util.Map;

public interface UserMapper {
    //用户名或邮箱登录
    User login(User user);

    //注册
    int regist(User user);

    //用户或邮箱是否存在
    int userExist(String username);

    User getUserById(int user_id);

    int getQuantity(int user_id);

    double getFunds(int user_id);

    //购买或退款或充值
    void doPurchase(Map<String,Object> map);
}
